package com.adcc.loadsheet.billing.mapper.mysql.contractuser;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 合同用户和机场关联表（计费范围）Mapper
 * Created by zhaoml on 2020-04-14.
 */
@Mapper
public interface ContractUserAirportEntityMapper {

    //根据合同用户删除
    int deleteByContractUserId(Integer contractUserId);

    //批量新建合同用户-机场关联关系
    void insertByBatch(@Param("contractUserId")Integer contractUserId, @Param("airportIds")String airportIds);

    //查询与合同用户绑定的机场
    List<Integer> selectAirportIds(Integer contractUserId);

    //查询与机场绑定的其他合同用户
    List<Integer> selectOtherContractUserIds(@Param("airportId")Integer airportId,@Param("contractUserId")Integer contractUserId);
}